package cn.edu.ctbu.sbadmin.school.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * <p>
 * 
 * </p>
 *
 * @author 关注公众号：MarkerHub
 * @since 2021-06-17
 */

@EqualsAndHashCode(callSuper = false)
@TableName(value = "lab_log_info")
public class LabLogInfo implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 班级id,包括了学期，老师,课程
     */
    private Long classId;

    /*
    * */
    @TableField(exist = false)
    private String className;

    /**
     * 实验室id
     */
    private Long labId;

    /**
     * 项目名称
     */
    private String projectName;

    /**
     * 开始节次
     */
    private Integer sectionFrom;

    /**
     * 结束节次
     */
    private Integer sectionTo;

    /**
     * 内容(2000字以内)
     */
    private String content;

    /**
     * 第几周
     */
    private Integer week;

    /**
     * 星期几
     */
    private Integer dayOfWeek;

    /**
     * 课程时间
     */
    private LocalDateTime courseTime;

    /**
     * 实验要求,1必须,2选修,3其它
     */
    private String requestType;

    /**
     * 实验类型,1演示,2验证,3综合,4设计,5其它
     */
    private Integer labType;

    /**
     * 建立时间
     */
    private LocalDateTime createTime;

    /**
     * 课程名称
     */
    @TableField(exist = false)

    private String courseName;

    /**
     * 课程类型
     */
    @TableField(exist = false)
    private Integer classPersonNumber;

    /**
     * 教师名称
     */
    @TableField(exist = false)
    private String userName;
    /**
     * 学期学年名称
     */
    @TableField(exist = false)
    private String name;

    public static long getSerialVersionUID() {
        return serialVersionUID;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Long getClassId() {
        return classId;
    }

    public void setClassId(Long classId) {
        this.classId = classId;
    }

    public String getClassName() {
        return className;
    }

    public void setClassName(String className) {
        this.className = className;
    }

    public Long getLabId() {
        return labId;
    }

    public void setLabId(Long labId) {
        this.labId = labId;
    }

    public String getProjectName() {
        return projectName;
    }

    public void setProjectName(String projectName) {
        this.projectName = projectName;
    }

    public Integer getSectionFrom() {
        return sectionFrom;
    }

    public void setSectionFrom(Integer sectionFrom) {
        this.sectionFrom = sectionFrom;
    }

    public Integer getSectionTo() {
        return sectionTo;
    }

    public void setSectionTo(Integer sectionTo) {
        this.sectionTo = sectionTo;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public Integer getWeek() {
        return week;
    }

    public void setWeek(Integer week) {
        this.week = week;
    }

    public Integer getDayOfWeek() {
        return dayOfWeek;
    }

    public void setDayOfWeek(Integer dayOfWeek) {
        this.dayOfWeek = dayOfWeek;
    }

    public LocalDateTime getCourseTime() {
        return courseTime;
    }

    public void setCourseTime(LocalDateTime courseTime) {
        this.courseTime = courseTime;
    }

    public String getRequestType() {
        return requestType;
    }

    public void setRequestType(String requestType) {
        this.requestType = requestType;
    }

    public Integer getLabType() {
        return labType;
    }

    public void setLabType(Integer labType) {
        this.labType = labType;
    }

    public LocalDateTime getCreateTime() {
        return createTime;
    }

    public void setCreateTime(LocalDateTime createTime) {
        this.createTime = createTime;
    }

    public String getCourseName() {
        return courseName;
    }

    public void setCourseName(String courseName) {
        this.courseName = courseName;
    }

    public Integer getClassPersonNumber() {
        return classPersonNumber;
    }

    public void setClassPersonNumber(Integer classPersonNumber) {
        this.classPersonNumber = classPersonNumber;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    @Override
    public boolean equals(Object obj) {
        if(obj instanceof  LabLogInfo){
            LabLogInfo a = (LabLogInfo) obj;
            return (this.id.equals(a.getId()));
        }
        return false;

    }

    @Override
    public int hashCode() {

        return (int)this.id.intValue();
    }

}
